package com.itheima.genericity;

import java.util.ArrayList;

public class GenericityDemo03 {
    public static void main(String[] args) {
        GenericityImpl gi = new GenericityImpl();
        Integer method = gi.method(1);
        System.out.println(method);//2
    }
}

interface Genericity<E>{
    E method(E e);
}

class GenericityImpl implements Genericity<Integer>{

    @Override
    public Integer method(Integer integer) {
        return ++integer;
    }
}
